home *** CD-ROM | disk | FTP | other *** search
Wrap
Text File | 1996-05-01 | 53.5 KB | 1,540 lines | [ TEXT/MPS ]
{ File: OCEMailbox.p Contains: Apple Open Collaboration Environment OCEMaibox Interfaces. Version: Technology: AOCE Toolbox 1.02 Release: Universal Interfaces 3.0d3 on Copland DR1 Copyright: © 1984-1996 by Apple Computer, Inc. All rights reserved. Bugs?: If you find a problem with this file, send the file and version information (from above) and the problem description to: Internet: apple.bugs@applelink.apple.com AppleLink: APPLE.BUGS } {$IFC UNDEFINED UsingIncludes} {$SETC UsingIncludes := 0} {$ENDC} {$IFC NOT UsingIncludes} UNIT OCEMailbox; INTERFACE {$ENDC} {$IFC UNDEFINED __OCEMAILBOX__} {$SETC __OCEMAILBOX__ := 1} {$I+} {$SETC OCEMailboxIncludes := UsingIncludes} {$SETC UsingIncludes := 1} {$IFC UNDEFINED __OCE__} {$I OCE.p} {$ENDC} {$IFC UNDEFINED __OCEMAIL__} {$I OCEMail.p} {$ENDC} {$IFC UNDEFINED __OCEMESSAGING__} {$I OCEMessaging.p} {$ENDC} {$IFC UNDEFINED __OCESTANDARDMAIL__} {$I OCEStandardMail.p} {$ENDC} {$PUSH} {$ALIGN MAC68K} {$LibExport+} {$IFC FOR_SYSTEM7_ONLY } { opaque references, iterators, and progress indicator } TYPE MBMailboxRef = Ptr; MBOpenContainerRef = Ptr; MBMailboxIterator = Ptr; MBMailItemIterator = Ptr; MBProgressIndicator = Ptr; MBCopyOperationRef = Ptr; MBNotificationRef = Ptr; CONST kMBMaxNumEnclosures = 50; { ******************************************************** } { Error codes, will be moved to OCEErrors.h } { ********************************************************* } kOCEIncompletedCallsErr = -15069; { calls operating within that container have not yet completed } kOCEInvalidMBContainerTokenErr = -15070; { the container token specified is invalid } kOCERefExhaustedErr = -15071; { all reference slots have been used } kOCEInvalidIteratorErr = -15072; { the Iterator specified is not valid } kOCEItemAlreadyLocalErr = -15073; { the letter is already local } kOCEIteratorOutOfRangeErr = -15074; { the iterator fell off the list of mail items } kOCEInvalidSortOrder = -15075; { sort order is invalid or unsupported } kOCEInvalidSortDirection = -15076; { sort direction is invalid or unsupported } kOCEInvalidMailItemFilter = -15077; { filter is invalid or unsupported } kOCECopyOperationCanceled = -15078; { copy operation is canceled } kOCECopyAlreadyCompleted = -15079; { copy operation cannot be canceled because it is already finished } kOCEInvalidContainerType = -15080; { the specified container type is invalid } kOCECannotUnmountMailboxErr = -15081; { cannot unmount the mailbox } kOCEInvalidLetterSpecErr = -15082; { letter spec is not valid } kOCECannotCloseContainerErr = -15083; { cannot close the container } kOCEFontNotDeclared = -15084; { cannot find font in font table } kOCEFontTableNotFound = -15085; { cannot find the font table in the letter } kOCENoProgressIndicator = 0; { ******************************************************** } { Mailbox Gestalt Values } { ******************************************************** } gestaltOCEMailboxAPIAttr = 'mbxa'; gestaltMailboxAPIPresent = $01; { Mailbox API is present } gestaltSupportsOutbox = $02; { supports outbox access } gestaltSupportsErrorLog = $04; { supports mailbox error log } { ******************************************************** } { Mailbox Data Structures } { ******************************************************** } TYPE MBMailboxToken = UInt32; MBMailboxDataPtr = ^MBMailboxData; MBMailboxData = RECORD mboxToken: MBMailboxToken; authID: AuthIdentity; dataType: OSType; creator: OSType; dataClass: OSType; modTime: MailTime; name: RString64; END; { MBPermissions control whether other applications can detect that mailbox has been mounted } MBPermissions = UInt32; CONST kMBPermissionsPublicMount = $00000000; kMBPermissionsPrivateMount = $00000001; { ******************************************************** } { Container Data Structures } { ********************************************************* } { These structures are used to manipulate and list the mailbox containers. A container is a logical collection of mailbox items. Examples of some standard containers are the inbox and the outbox. } TYPE MBContainerType = UInt32; CONST kMBUndefinedContainerType = $00000000; kMBInboxContainerType = 'inbx'; kMBOutboxContainerType = 'otbx'; TYPE MBContainerTokenPtr = ^MBContainerToken; MBContainerToken = RECORD reserved: ARRAY [0..2] OF UInt32; END; MBContainerStatus = UInt32; CONST kMBConnectionStatusUndefined = $00000000; kMBContainerStatusConnected = $00000001; kMBContainerStatusNotConnected = $00000002; TYPE MBContainerFlags = UInt32; CONST kMBContainerLocal = $00000000; kMBContainerRemote = $00000001; kMBContainerLocalAndRemote = $00000002; TYPE MBContainerLocation = UInt32; CONST kMBInboxContainerCreator = 'ptps'; kMBOutboxContainerCreator = 'ptps'; kMBContainerSystemClass = 'sys '; kMBContainerPMSAMClass = 'pmsm'; kMBContainerUserClass = 'user'; TYPE MBContainerClass = UInt32; MBContainerDataPtr = ^MBContainerData; MBContainerData = RECORD containerToken: MBContainerToken; reserved: MBContainerToken; location: MBContainerLocation; status: MBContainerStatus; capabilities: ARRAY [0..2] OF MBContainerFlags; containerType: OSType; creator: OSType; containerClass: MBContainerClass; name: RString64; END; AddressAsType = SInt8; { AddressAsType is actually an enumerated type and its constants kAddressedAs_TO, kAddressedAs_CC, and kAddressedAs_BCC are defined in OCEMail.h in an anonymous enum list. } MBInboxLetterDataPtr = ^MBInboxLetterData; MBInboxLetterData = RECORD seqNum: MailSeqNum; letterFlags: MailLetterFlags; approximateSize: UInt32; { approximate size of letter } indications: MailIndications; creatorType: OCECreatorType; sendTime: MailTime; { time that message was sent } family: OSType; filler: SInt8; addressedToMe: SInt8; { addressed as TO, CC or BCC } sender: RString64; subject: RString64; { subject is truncated } END; MBOutboxLetterDataPtr = ^MBOutboxLetterData; MBOutboxLetterData = RECORD seqNum: MailSeqNum; family: OSType; { family this message belongs to } creatorType: OCECreatorType; messageID: IPMMsgID; submitTime: MailTime; approximateSize: UInt32; { approximate size of letter } recipientCount: UInt32; { number of recipients of message } pendingRecipientCount: UInt32; { number of recipients left to send by this slot } state: PMSAMStatus; subject: RString64; { subject is truncated } END; MBMailItemType = UInt32; CONST kMBMailItemTypeUndefined = $00000000; kMBInboxLetter = $00000001; kMBOutboxLetter = $00000002; { Filters for MBGetMailItemCount } kMBNoFilterMask = $00000000; kMBInTrashFilterMask = $00000004; TYPE MBMailItemFilter = UInt32; MBMailItemDataPtr = ^MBMailItemData; MBMailItemData = RECORD itemType: MBMailItemType; CASE INTEGER OF 0: ( inboxLetter: MBInboxLetterData; ); 1: ( outboxLetter: MBOutboxLetterData; ); END; { Used to mark an item read or unread using MBMarkLetter } MBLetterReadStatus = UInt32; CONST kMBLeaveReadMark = $00000000; kMBMarkLetterRead = $00000001; kMBMarkLetterUnread = $00000002; { Used to mark an item in or out of trash using MBMarkLetter } TYPE MBLetterTrashStatus = UInt32; CONST kMBLeaveTrashMark = $00000000; kMBMarkLetterInTrash = $00000001; kMBMarkLetterNotInTrash = $00000002; { ******************************************************** } { Changes Enumeration Data Structures } { ********************************************************* } TYPE MBMailItemChangeType = UInt32; CONST kMBNoChange = $00000000; kMBNewLetter = $00000001; kMBDeletedLetter = $00000002; kMBChangedLetter = $00000004; kMBAllChanges = $7FFFFFFF; TYPE MBNotificationMask = UInt32; CONST kMBNoNotification = $00000000; kMBNotificationNewMailItem = $00000001; kMBNotificationDeletedMailItem = $00000002; kMBNotificationChangedMailItem = $00000004; kMBNotificationMBReset = $00000008; { must re-enumerate container contents } kMBNotificationMailboxGoingAway = $00000010; kMBNotificationMSAMError = $00000020; kMBIgnoreThisNotification = $80000000; { for future extensibility } kMBAllNotifications = $7FFFFFFF; { ********************************************************* } { For mail item iterators } { ********************************************************* } TYPE MBSortOrder = UInt32; CONST kMBSortOrderMailSeqNum = $00000001; TYPE MBSortDirection = UInt32; CONST kMBAscending = 0; { forward declaration } TYPE MailboxParamPtr = ^MailboxParam; { ------------------------------------------------------------------------------ } { Parameter Blocks for the Operations } { ------------------------------------------------------------------------------ } { ******************************************************** } { Mailbox Operations } { ******************************************************** } { Mounts the mailbox. Returns a mailboxRef which should be used on all future operations. } MBMountMailboxPBPtr = ^MBMountMailboxPB; MBMountMailboxPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; authID: AuthIdentity; { --> valid user authentication } reserved1: SInt32; { --> must be set to 0 } reserved2: UInt32; { --> must be set to 0 } mailboxDataPtr: MBMailboxDataPtr; { <--> user supplied buffer for mailbox data } mailboxRef: MBMailboxRef; { <-- allows user to access contents of the mailbox } END; { Unmounts the Mailbox. After this call, the mailboxRef is no longer valid. } MBUnmountMailboxPBPtr = ^MBUnmountMailboxPB; MBUnmountMailboxPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; mailboxRef: MBMailboxRef; { --> ref of mailbox to unmount } reserved: SInt32; { --> must be set to 0 } END; { ******************************************************** } { Container and Mail Item Operations } { ********************************************************* } { Opens the container for use, returns a containerRef which should be used in all future Container operations } MBOpenContainerPBPtr = ^MBOpenContainerPB; MBOpenContainerPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; mailboxRef: MBMailboxRef; { --> authenticates client to access contents } containerToken: MBContainerToken; { --> containerToken, persistent accross sessions } containerRef: MBOpenContainerRef; { <-- specifies the mounted mailbox we are dealing with } END; { Closes the container and invalidates the containerRef } MBCloseContainerPBPtr = ^MBCloseContainerPB; MBCloseContainerPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> ref to container you wish to close } forceClose: BOOLEAN; { --> true to close in spite of outstanding letters that have not been closed } filler: SInt8; END; { Reconnect open container to remote service } MBReconnectOpenContainerPBPtr = ^MBReconnectOpenContainerPB; MBReconnectOpenContainerPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> the container ref to which to reconnect } reserved1: UInt32; { --> must be set to 0 } reserved2: UInt32; { --> must be set to 0 } END; { Returns the mail item with the specified mail sequence number } MBGetMailItemDataPBPtr = ^MBGetMailItemDataPB; MBGetMailItemDataPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> ref to container from which you wish to get data } seqNum: MailSeqNum; { --> mail sequence number of the letter } dataPtr: MBMailItemDataPtr; { <--> user supplied buffer where to copy data } END; { Returns the number of items in the container (filtered, if specified) } MBGetMailItemCountPBPtr = ^MBGetMailItemCountPB; MBGetMailItemCountPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> container whose items are to be counted } filter: MBMailItemFilter; { --> filter to apply when counting items } count: UInt32; { <-- number of items of that type in the container } END; { Allocates the memory and sets the Iterator to the first of the mail items of that type in the container. } MBCreateMailItemIteratorPBPtr = ^MBCreateMailItemIteratorPB; MBCreateMailItemIteratorPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> ref of container where iterator should be set } sortOrder: MBSortOrder; { --> sort order } sortDirection: MBSortDirection; { --> sort direction } reserved: ARRAY [0..1] OF SInt32; { --> must be set to 0 } iterator: MBMailItemIterator; { <-- iterator returned here, client allocates memory } END; { Dispose of the MBMailItemIterator } MBDisposeMailItemIteratorPBPtr = ^MBDisposeMailItemIteratorPB; MBDisposeMailItemIteratorPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; iterator: MBMailItemIterator; { --> the iterator to dispose of } END; MBMailItemIteratePBPtr = ^MBMailItemIteratePB; MBMailItemIteratePB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; iterator: MBMailItemIterator; { <--> iterator to move } dataPtr: MBMailItemDataPtr; { <--> user supplied buffer where to copy data } END; MBResetMailItemIteratorPBPtr = ^MBResetMailItemIteratorPB; MBResetMailItemIteratorPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; iterator: MBMailItemIterator; { <--> mail item iterator to reset } END; { MarkLetter Read/Unread and/or In Trash/Out of Trash. } MBMarkLetterPBPtr = ^MBMarkLetterPB; MBMarkLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> container in which letter resides } seqNum: MailSeqNum; { --> mail sequence number of the letter } readMark: MBLetterReadStatus; { --> must be kMBLetterRead, kMBLetterUnread or kMBLeaveReadMark } trashMark: MBLetterTrashStatus; { --> must be kMBLetterNotInTrash, kMBLetterInTrash or kMBLeaveTrashMark } END; { Stores the MailItem locally. } MBCopyLocalPBPtr = ^MBCopyLocalPB; MBCopyLocalPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> container in which letter resides } seqNum: MailSeqNum; { --> mail sequence number of the desired letter } progressIndicator: MBProgressIndicator; { --> created using MBCreateProgressIndicatoror kOCENoProgressIndicator if client does not desire progress indication. } copyOperationRef: MBCopyOperationRef; { <-- ref to this copy operation for use in cancel } newSeqNum: MailSeqNum; { <-- seqNum of new letter after successful operation } END; MBCopyToFilePBPtr = ^MBCopyToFilePB; MBCopyToFilePB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> container in which letter resides } seqNum: MailSeqNum; { --> mail sequence number of the desired letter } specPtr: FSSpecPtr; { --> spec of file which will contain the local copy } progressIndicator: MBProgressIndicator; { --> created using MBCreateProgressIndicator or kOCENoProgressIndicator if client does not desire progress indication. } copyOperationRef: MBCopyOperationRef; { <-- ref to this copy operation for use in cancel } END; { Cancels the copy operation, if possible. } MBCancelCopyPBPtr = ^MBCancelCopyPB; MBCancelCopyPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; copyOperationRef: MBCopyOperationRef; { --> reference to copyLocal or copyToFile operation to cancel } END; { An irrevocable delete of an item from a container. } MBDeleteLetterPBPtr = ^MBDeleteLetterPB; MBDeleteLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> container in which letter resides } seqNum: MailSeqNum; { --> mail sequence number of the letter to delete } END; { Forces a MailItem to be sent right now. This operation only works on MailItems in the outbox. } MBSendNowPBPtr = ^MBSendNowPB; MBSendNowPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> ref of the outbox container in which letter resides } seqNum: MailSeqNum; { --> mail sequence number of the letter to send } timeOut: Duration; { --> time in seconds to wait for a response from server } END; { ******************************************************** } { Notification and Changes Enumeration Operations } { ********************************************************* } MBNotificationProcPtr = ProcPtr; { PROCEDURE MBNotification(containerRef: MBOpenContainerRef; actualChanges: MBNotificationMask; contextPtr: UNIV Ptr; VAR item: MBMailItemData); } MBNotificationUPP = UniversalProcPtr; { Allows a client to specify a callback routine and parameters. } MBRegisterNotificationPBPtr = ^MBRegisterNotificationPB; MBRegisterNotificationPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> container for which to receive notifications } handler: MBNotificationUPP; { --> UPP of callback to call when changes occur } mask: MBNotificationMask; { --> which events should cause a notification } contextPtr: Ptr; { --> pointer to client-defined buffer is passed to handler } notificationRef: MBNotificationRef; { <-- reference to the newly registered notification } reserved: SInt32; { --> must be set to 0 } END; { Allows client to clear the callback info. } MBUnregisterNotificationPBPtr = ^MBUnregisterNotificationPB; MBUnregisterNotificationPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; notificationRef: MBNotificationRef; { --> reference to the notification to unregister } END; { ******************************************************** } { Progress Indication Operations } { ********************************************************* } { Creates a progress indicator for tracking progress of a copy operation from MBCopyToFile or MBCopyLocal. } MBCreateProgressIndicatorPBPtr = ^MBCreateProgressIndicatorPB; MBCreateProgressIndicatorPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; progressIndicator: MBProgressIndicator; { <-- a progress indicator is returned here } END; { Dispose the progress indicator that was previously allocated by MBCreateProgressIndicator. } MBDisposeProgressIndicatorPBPtr = ^MBDisposeProgressIndicatorPB; MBDisposeProgressIndicatorPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; progressIndicator: MBProgressIndicator; { --> the progress indicator to be destroyed } END; { Returns the current level of progress that has been completed. The following fields can be polled during the the move in order to provide a "progress" indicator. The operation will be done when workCompleted equals totalWorkAmount. totalWorkAmount is pretty much a random number and is not an indication of the amount of work involved. } MBGetCurrentProgressPBPtr = ^MBGetCurrentProgressPB; MBGetCurrentProgressPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; progressIndicator: MBProgressIndicator; totalWorkAmount: UInt32; { <-- total amount of work that needs to be done, arbitrary units } workCompleted: UInt32; { <-- how much work was completed, between 0 and fTotalWorkAmount } END; { ******************************************************** } { Miscellaneous Operations } { ********************************************************* } { Returns the LetterSpec of a letter for use with Mailer APIs. } MBGetLetterSpecPBPtr = ^MBGetLetterSpecPB; MBGetLetterSpecPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> container within which the letter resides } seqNum: MailSeqNum; { --> mail sequence number of the letter } specPtr: LetterSpecPtr; { <--> letter spec is returned here, client-supplied buffer } END; { Obtain a mail sequence number and open container reference from a letter spec } MBConvertLetterSpecPBPtr = ^MBConvertLetterSpecPB; MBConvertLetterSpecPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; specPtr: LetterSpecPtr; { --> letter spec to convert } containerRef: MBOpenContainerRef; { <-- open container reference for input letter spec } seqNum: MailSeqNum; { <-- mail sequence number for input letter spec } END; { Returns the containerID given a well known container type } MBGetContainerTokenPBPtr = ^MBGetContainerTokenPB; MBGetContainerTokenPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; mailboxRef: MBMailboxRef; { --> the ref of the desired mailbox } containerType: MBContainerType; { --> one of the well known container types } containerToken: MBContainerToken; { <-- the container Token returned here } END; { Returns ContainerData for a given ContainerToken. } MBGetContainerDataFromTokenPBPtr = ^MBGetContainerDataFromTokenPB; MBGetContainerDataFromTokenPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; mailboxRef: MBMailboxRef; { --> the ref of the desired mailbox } containerToken: MBContainerToken; { --> container you wish to get data from } dataPtr: MBContainerDataPtr; { --> user supplied buffer where to write the data } END; { ******************************************************** } { Contents Operations } { ********************************************************* } { Opens a letter that is currently in a container. } MBOpenLetterPBPtr = ^MBOpenLetterPB; MBOpenLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; containerRef: MBOpenContainerRef; { --> open container where the letter resides } seqNum: MailSeqNum; { --> mail sequence number of the desired letter } msgRef: MailMsgRef; { <-- the MailMsgRef authenticates the client to view the contents } END; { Opens a letter that is currently on the disk. } MBOpenDiskLetterPBPtr = ^MBOpenDiskLetterPB; MBOpenDiskLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; diskLetter: FSSpec; { --> the location of the mail item on disk } msgRef: MailMsgRef; { <-- the MailMsgRef authenticates the client to view the contents } END; { Closes a letter that is currently open. } MBCloseLetterPBPtr = ^MBCloseLetterPB; MBCloseLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> mail sequence number of the letter to close } END; { Opens a letter that is nested within another. } MBOpenNestedLetterPBPtr = ^MBOpenNestedLetterPB; MBOpenNestedLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> MailMsgRef of the containing letter } nestedMsgRef: MailMsgRef; { <-- MailMsgRef of the nested letter } END; { Returns the path where the enclosures of a certain letter are kept. } MBReadEnclosureFSSpecPBPtr = ^MBReadEnclosureFSSpecPB; MBReadEnclosureFSSpecPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> message for which to read enclosure information } enclosureDir: FSSpec; { <-- full path of directory where enclosures are stored } END; { Returns the path where the content of a certain letter is kept. } MBReadContentFSSpecPBPtr = ^MBReadContentFSSpecPB; MBReadContentFSSpecPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> message for which to read the content } enclosureDir: FSSpec; { <-- full path and file name for main enclosure } END; { Enumerates across the blocks of a letter. } MBEnumerateBlocksPBPtr = ^MBEnumerateBlocksPB; MBEnumerateBlocksPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> letter whose blocks are to be enumerated } startIndex: UInt16; { --> starting block index } buffer: MailBuffer; { <--> user-allocated buffer where blocks are returned } nextIndex: UInt16; { <-- Index of next block returned here } more: BOOLEAN; { <-- true if more blocks to process } filler: SInt8; END; { Returns a buffer of all the recipients of a certain letter } MBReadRecipientsPBPtr = ^MBReadRecipientsPB; MBReadRecipientsPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> message about which to get recipient info } attrID: MailAttributeID; { --> type of recipient, kMailFromBit through kMailBccBit } startIndex: UInt16; { --> position in recipient list at which to begin, starts at 1 } buffer: MailBuffer; { <--> buffer contains a Mail Reply. Each tuple is an OCEPackedRecipient. Each tuple is word aligned. } nextIndex: UInt16; { <-- Index of next tuple that didn't fit in buffer } more: BOOLEAN; { <-- true if there are more recipient tuples to process } filler: SInt8; END; { Reads the attributes of a letter as specified in the requestMask. } { buffer returned will contain the attribute values of the attributes indicated in responseMask, from the attribute indicated by the least significant bit set to the attribute indicated by the most significant bit set. Note that recipients - from, to, cc, bcc cannot be read using this call. Use GetRecipients to read these. } MBReadAttributesPBPtr = ^MBReadAttributesPB; MBReadAttributesPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> letter whose attributes you wish to get } requestMask: MailAttributeBitmap; { --> which attributes to get, kMailIndicationsBit through kMailSubjectBit } buffer: MailBuffer; { <--> attributes returned in this user supplied buffer } responseMask: MailAttributeBitmap; { <-- returns bits of those attributes that were returned } more: BOOLEAN; { <-- true if there are more recipient tuples to process } filler: SInt8; END; { Reads the block of a letter. } MBReadBlockPBPtr = ^MBReadBlockPB; MBReadBlockPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> letter whose blocks you wish to read } blockType: OCECreatorType; { --> specifies creator and type of the block to read } blockIndex: UInt16; { --> relative position of the block of that type to read } buffer: MailBuffer; { <--> user suppied buffer to reciev the information } dataOffset: UInt32; { --> byte offset within the block at which to start reading } endOfBlock: BOOLEAN; { <-- indicates whether the call has returned the entire block } filler: SInt8; remaining: UInt32; { <-- number of bytes of data remaining in the block } END; { Returns a SignatureContext that can be used to verify a signature. } MBVerifySignaturePBPtr = ^MBVerifySignaturePB; MBVerifySignaturePB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> letter containing the signature to verify } signatureContext: SIGContextPtr; { --> previously obtained signature context } END; { Creates a letter given the relevant info about the letter. } MBCreateLetterPBPtr = ^MBCreateLetterPB; MBCreateLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { <-- MailMsgRef of the letter just created } senderIdentity: AuthIdentity; { --> authenticated identity of the sender } msgType: IPMMsgType; { --> type, creator, and class of the sending application } diskForm: BOOLEAN; { --> true to create letter on disk, otherwise in the outbox } filler: SInt8; diskLetter: FSSpec; { --> diskForm is true, it specifies where to create the letter } bccRecipients: BOOLEAN; { --> set to true if creating letter with bcc recipients } filler2: SInt8; END; { Submits a letter for processing. } MBSubmitLetterPBPtr = ^MBSubmitLetterPB; MBSubmitLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> ref to the letter that you wish to submit } submitFlag: BOOLEAN; { --> throw letter away if submitFlag is false } filler: SInt8; letterID: MailLetterID; { <-- persistent ID of the letter accross the whole system } signaturePtr: SIGSignaturePtr; { --> pointer to digital signature } signatureSize: Size; { --> size of the digital signature } signatureContext: SIGContextPtr; { --> pointer to the signature context } END; { Begin a nested mail item within some mail item. } MBBeginNestedLetterPBPtr = ^MBBeginNestedLetterPB; MBBeginNestedLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> the letter within which you wish to nest } reserved: SInt32; { --> must be set to NIL } msgType: IPMMsgType; { --> creator and type of the nested message to create } END; { End the nested mail item. This function is always executed synchronously. } MBEndNestedLetterPBPtr = ^MBEndNestedLetterPB; MBEndNestedLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> the message containing the nested letter to end } END; { Add attributes to a mail item. } MBAddAttributePBPtr = ^MBAddAttributePB; MBAddAttributePB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> the letter to wich you wish to add an attribute } attrID: MailAttributeID; { --> the type of attribute to add } buffer: MailBuffer; { <--> attributes stored in buffer are copied to the mail item } END; { Adds an enclosure to a mail item. This function is always executed synchronously. } MBAddEnclosurePBPtr = ^MBAddEnclosurePB; MBAddEnclosurePB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> the letter to wich you wish to add an enclosure } contentEnclosure: BOOLEAN; { --> whethet this enclosure contains the main content of the mail } filler: SInt8; hfs: BOOLEAN; { --> true if in the file system, false if in memory } append: BOOLEAN; { --> whether to append data in buffer to current enclosure } buffer: MailBuffer; { <--> unused if hfs is true, otherwise it contains the file’s resource and data forks } enclosure: FSSpec; { --> specifies the file or folder you wish to enclose } addlInfo: MailEnclosureInfo; { --> specifies file system info for the enclosure } END; { Adds a block to a mail item. } MBAddBlockPBPtr = ^MBAddBlockPB; MBAddBlockPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> the message to wich you wish to add a block } refCon: SInt32; { --> reserved for your use } blockType: OCECreatorType; { --> creator and type of the block that you want to write } append: BOOLEAN; { --> whether to append the data in you buffer to the current block } filler: SInt8; buffer: MailBuffer; { <--> stores the data you want to write to the message } mode: MailBlockMode; { --> if blockType is kMailTunnelLtrType or kMailHopInfoType mode is assumed to be kMailFromMark } offset: UInt32; { --> offset to use to determine the starting point of the write set to 0 to start new block, ignored when append is false } END; { Adds a letter to another one. } MBAddLetterPBPtr = ^MBAddLetterPB; MBAddLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; newMsgRef: MailMsgRef; { --> the new letter you are composing } msgRef: MailMsgRef; { --> the original letter you want to add to the new letter } END; { Adds content to a mail item. } MBAddContentPBPtr = ^MBAddContentPB; MBAddContentPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> message from which to add some content } segmentType: MailSegmentType; { --> segment type of data tou want to write } append: BOOLEAN; { --> whether to copy data from buffer into mail item } filler: SInt8; buffer: MailBuffer; { <--> place the data in this buffer } textScrap: StScrpRecPtr; { --> a pointer to a style scrap structure } startNewScript: BOOLEAN; { --> whether the data in buffer uses a new character set } filler2: SInt8; script: ScriptCode; { --> valid only if startNewScript is true } END; { Reads the content of a mail item. } MBReadContentPBPtr = ^MBReadContentPB; MBReadContentPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> message from which to read the content } segmentMask: MailSegmentMask; { --> the types of segments that you want to read } buffer: MailBuffer; { <--> user suppiled buffer into which to write the segment } textScrap: StScrpRecPtr; { <--> a pointer to a style scrap structure } script: ScriptCode; { <-- the character set of the text placed in your buffer } segmentType: MailSegmentType; { <-- the type of the current data segment } endOfScript: BOOLEAN; { <-- whether the text in your buffer is the end of a script run } endOfSegment: BOOLEAN; { <-- whether we reached the end of a segment } endOfContent: BOOLEAN; { <-- whether we reached the end of the letter's content block } filler: SInt8; segmentLength: SInt32; { <-- number of bytes in the current segment } segmentID: SInt32; { <--> segment identifier } END; { Adds another recipient to a mail item. } MBAddRecipientPBPtr = ^MBAddRecipientPB; MBAddRecipientPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> message to which to add recipient information } attrID: MailAttributeID; { --> type of recipient to add to the message } recipient: MailRecipientPtr; { --> where you provide complete addressing information about recipient } invalid: BOOLEAN; { --> Must be set to false } filler: SInt8; END; { Gets a font name from the letter, given a font number } MBGetFontNameFromLetterPBPtr = ^MBGetFontNameFromLetterPB; MBGetFontNameFromLetterPB = RECORD qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; msgRef: MailMsgRef; { --> letter reference from which to get font table } fontNum: SInt16; { --> font number to obtain name of } filler: SInt16; fontName: StringPtr; { <--> user supplied buffer to be filled with font name } END; MailboxParam = RECORD CASE INTEGER OF 0: ( qLink: Ptr; reservedH1: SInt32; reservedH2: SInt32; ioCompletion: MSAMIOCompletionUPP; ioResult: OSErr; saveA5: SInt32; reqCode: SInt16; ); { Mailbox Operations } 1: ( mountMailboxPB: MBMountMailboxPB; ); 2: ( unmountMailboxPB: MBUnmountMailboxPB; ); { Container and Letter Operations } 3: ( openContainerPB: MBOpenContainerPB; ); 4: ( closeContainerPB: MBCloseContainerPB; ); 5: ( reconnectOpenContainerPB: MBReconnectOpenContainerPB; ); 6: ( getMailItemDataPB: MBGetMailItemDataPB; ); 7: ( getMailItemCountPB: MBGetMailItemCountPB; ); 8: ( createMailItemIteratorPB: MBCreateMailItemIteratorPB; ); 9: ( disposeMailItemIteratorPB: MBDisposeMailItemIteratorPB; ); 10: ( mailItemIteratePB: MBMailItemIteratePB; ); 11: ( resetMailItemIteratorPB: MBResetMailItemIteratorPB; ); 12: ( markLetterPB: MBMarkLetterPB; ); 13: ( copyLocalPB: MBCopyLocalPB; ); 14: ( copyToFilePB: MBCopyToFilePB; ); 15: ( cancelCopyPB: MBCancelCopyPB; ); 16: ( deleteLetterPB: MBDeleteLetterPB; ); 17: ( sendNowPB: MBSendNowPB; ); { Notification and Changes Iterator Operations } 18: ( registerNotificationPB: MBRegisterNotificationPB; ); 19: ( unregisterNotificationPB: MBUnregisterNotificationPB; ); { Progress Indicator Operations } 20: ( createProgressIndicatorPB: MBCreateProgressIndicatorPB; ); 21: ( disposeProgressIndicatorPB: MBDisposeProgressIndicatorPB; ); 22: ( getCurrentProgressPB: MBGetCurrentProgressPB; ); { Miscellaneous Operations } 23: ( getLetterSpecPB: MBGetLetterSpecPB; ); 24: ( convertLetterSpecPB: MBConvertLetterSpecPB; ); 25: ( getContainerTokenPB: MBGetContainerTokenPB; ); 26: ( getContainerDataFromTokenPB: MBGetContainerDataFromTokenPB; ); { Contents Operations } 27: ( openLetterPB: MBOpenLetterPB; ); 28: ( openDiskLetterPB: MBOpenDiskLetterPB; ); 29: ( closeLetterPB: MBCloseLetterPB; ); 30: ( openNestedLetterPB: MBOpenNestedLetterPB; ); 31: ( readEnclosureFSSpecPB: MBReadEnclosureFSSpecPB; ); 32: ( readContentFSSpecPB: MBReadContentFSSpecPB; ); 33: ( enumerateBlocksPB: MBEnumerateBlocksPB; ); 34: ( readRecipientsPB: MBReadRecipientsPB; ); 35: ( readAttributesPB: MBReadAttributesPB; ); 36: ( readBlockPB: MBReadBlockPB; ); 37: ( verifySignaturePB: MBVerifySignaturePB; ); 38: ( createLetterPB: MBCreateLetterPB; ); 39: ( submitLetterPB: MBSubmitLetterPB; ); 40: ( beginNestedLetterPB: MBBeginNestedLetterPB; ); 41: ( endNestedLetterPB: MBEndNestedLetterPB; ); 42: ( addAttributePB: MBAddAttributePB; ); 43: ( addEnclosurePB: MBAddEnclosurePB; { this variant is SYSTEM8_DEPRECATED } ); 44: ( addBlockPB: MBAddBlockPB; ); 45: ( addLetterPB: MBAddLetterPB; ); 46: ( addContentPB: MBAddContentPB; ); 47: ( readContentPB: MBReadContentPB; ); 48: ( addRecipientPB: MBAddRecipientPB; ); 49: ( getFontNameFromLetterPB: MBGetFontNameFromLetterPB; ); END; { ------------------------------------------------------------------------------ } { FUNCTION PROTOTYPES } { ------------------------------------------------------------------------------ } { ******************************************************** } { Mailbox Operations } { ********************************************************* } FUNCTION MBMountMailbox(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0578, $AA5E; {$ENDC} FUNCTION MBUnmountMailbox(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0579, $AA5E; {$ENDC} { ******************************************************** } { MailItem Operations } { ********************************************************* } FUNCTION MBOpenContainer(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0582, $AA5E; {$ENDC} FUNCTION MBCloseContainer(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0583, $AA5E; {$ENDC} FUNCTION MBReconnectOpenContainer(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $057F, $AA5E; {$ENDC} FUNCTION MBGetMailItemData(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0592, $AA5E; {$ENDC} FUNCTION MBGetMailItemCount(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0584, $AA5E; {$ENDC} FUNCTION MBCreateMailItemIterator(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0585, $AA5E; {$ENDC} FUNCTION MBDisposeMailItemIterator(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0586, $AA5E; {$ENDC} FUNCTION MBMailItemIterate(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0587, $AA5E; {$ENDC} FUNCTION MBResetMailItemIterator(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0588, $AA5E; {$ENDC} FUNCTION MBMarkLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $058C, $AA5E; {$ENDC} FUNCTION MBCopyLocal(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $058D, $AA5E; {$ENDC} FUNCTION MBCopyToFile(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $058E, $AA5E; {$ENDC} FUNCTION MBCancelCopy(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $058F, $AA5E; {$ENDC} FUNCTION MBDeleteLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0590, $AA5E; {$ENDC} FUNCTION MBSendNow(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0591, $AA5E; {$ENDC} { ******************************************************** } { MailItem Changes Operations } { ********************************************************* } FUNCTION MBRegisterNotification(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0596, $AA5E; {$ENDC} FUNCTION MBUnregisterNotification(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0597, $AA5E; {$ENDC} { ******************************************************** } { Progress Indicator Operations } { ******************************************************** } FUNCTION MBCreateProgressIndicator(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $059C, $AA5E; {$ENDC} FUNCTION MBDisposeProgressIndicator(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $059D, $AA5E; {$ENDC} FUNCTION MBGetCurrentProgress(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $059E, $AA5E; {$ENDC} { ******************************************************** } { Miscellaneous Operations } { ********************************************************* } FUNCTION MBGetLetterSpec(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $059F, $AA5E; {$ENDC} FUNCTION MBConvertLetterSpec(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0599, $AA5E; {$ENDC} FUNCTION MBGetContainerToken(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0589, $AA5E; {$ENDC} FUNCTION MBGetContainerDataFromToken(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $058A, $AA5E; {$ENDC} { ******************************************************** } { Contents Operations } { ********************************************************* } FUNCTION MBOpenLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A0, $AA5E; {$ENDC} FUNCTION MBOpenDiskLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A1, $AA5E; {$ENDC} FUNCTION MBCloseLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A2, $AA5E; {$ENDC} FUNCTION MBOpenNestedLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A3, $AA5E; {$ENDC} FUNCTION MBReadEnclosureFSSpec(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A4, $AA5E; {$ENDC} FUNCTION MBReadContentFSSpec(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A5, $AA5E; {$ENDC} FUNCTION MBEnumerateBlocks(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A6, $AA5E; {$ENDC} FUNCTION MBReadRecipients(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A7, $AA5E; {$ENDC} FUNCTION MBReadAttributes(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A8, $AA5E; {$ENDC} FUNCTION MBReadBlock(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05A9, $AA5E; {$ENDC} FUNCTION MBVerifySignature(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05AA, $AA5E; {$ENDC} FUNCTION MBCreateLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05AB, $AA5E; {$ENDC} FUNCTION MBSubmitLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05AC, $AA5E; {$ENDC} FUNCTION MBBeginNestedLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05AD, $AA5E; {$ENDC} FUNCTION MBEndNestedLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05AE, $AA5E; {$ENDC} FUNCTION MBAddAttribute(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05AF, $AA5E; {$ENDC} FUNCTION MBAddEnclosure(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05B0, $AA5E; {$ENDC} FUNCTION MBAddBlock(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05B1, $AA5E; {$ENDC} FUNCTION MBAddLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05B2, $AA5E; {$ENDC} FUNCTION MBAddContent(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05B3, $AA5E; {$ENDC} FUNCTION MBReadContent(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05B4, $AA5E; {$ENDC} FUNCTION MBAddRecipient(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $05B5, $AA5E; {$ENDC} FUNCTION MBGetFontNameFromLetter(VAR mailParam: MailboxParam; async: BOOLEAN): OSErr; {$IFC NOT GENERATINGCFM} INLINE $3F3C, $0598, $AA5E; {$ENDC} CONST uppMBNotificationProcInfo = $00003FC0; FUNCTION NewMBNotificationProc(userRoutine: MBNotificationProcPtr): MBNotificationUPP; {$IFC NOT GENERATINGCFM } INLINE $2E9F; {$ENDC} PROCEDURE CallMBNotificationProc(containerRef: MBOpenContainerRef; actualChanges: MBNotificationMask; contextPtr: UNIV Ptr; VAR item: MBMailItemData; userRoutine: MBNotificationUPP); {$IFC NOT GENERATINGCFM} INLINE $205F, $4E90; {$ENDC} {$ENDC} {$ALIGN RESET} {$POP} {$SETC UsingIncludes := OCEMailboxIncludes} {$ENDC} {__OCEMAILBOX__} {$IFC NOT UsingIncludes} END. {$ENDC}